<?

include("sqlconnect.php");

session_start();
$usrid = $_SESSION['usrid'];

$email_id = $_POST['email_id'];
$user_dob = $_POST['user_dob'];
$fname = $_POST['fname'];
$lname = $_POST['lname'];
$sec_q = $_POST['sec_a'];
$sec_a = $_POST['sec_a'];

$query= " UPDATE users SET email_id = '".$email_id."'
user_dob = '".$user_dob."',
user_fname = '".$fname."',
user_lname = '".$lname."',
sec_q = '".$sec_a."',
sec_a = '".$sec_q."' WHERE user_id = ".$usrid.";";
  
  
  $result= mysql_query($query) or die(mysql_error());
  
  echo(mysql_affected_rows());
  
?>